//
// Created by zqh on 2023/11/26.
//

//#ifndef _BSP_PWM_H
//#define _BSP_PWM_H
//
//#endif //_BSP_PWM_H

/**
  ******************************************************************************
  * @file    driver_pwm.h
  * @author  XJTU ROBOMASTER Team
  * @brief   This file contains all the tim initialization function
  ******************************************************************************
  * @attention
  *
  * Please add comments after adding or deleting functions to ensure code
  * specification.
  *
  ******************************************************************************
  */

/* Define to prevent recursive inclusion -------------------------------------*/
#ifndef BSP_PWM_H
#define BSP_PWM_H

/* Includes ------------------------------------------------------------------*/
#include "main.h"
#include "stdint.h"
#include "tim.h"
#ifdef __cplusplus
extern "C" {
#endif
//C
/* Exported constants --------------------------------------------------------*/
#define PWM1 ((&htim1)->Instance->CCR1)//PB3

/* Exported variables --------------------------------------------------------*/
extern TIM_HandleTypeDef htim1;
extern TIM_HandleTypeDef htim8;

/* Exported functions --------------------------------------------------------*/
void PWM_Start(void);




void TIM_Set_PWM(TIM_HandleTypeDef *tim_pwmHandle, uint8_t Channel, uint16_t value);

#ifdef __cplusplus
}
#endif
//C++

#endif //BSP_PWM_H
/************************ (C) COPYRIGHT XJTU ROBOMASTER ********END OF FILE****/
